package ar.edu.unicen.exa.isistan.archassis.ia.util;

public class AverageCalculator {

	private float accumulator = 0;
	private int count = 0;
	
	public void add(float value) {
		accumulator += value;
		count ++;
	}
	public void rem(float value) {
		accumulator -= value;
		count --;
	}

	public float getAVG() {
		if (count == 0) {
			return 0;
		}
		return accumulator / count;
	}

}
